﻿namespace SilenthinkContract.Domain
{
    public class PayTrade:Versionable<string>
    {
        /// <summary>
        /// 用户id
        /// </summary>
        public int UserId { get; set; }

        /// <summary>
        /// 交易类型 0为充值 1为订单支付 2为竞购订单支付
        /// </summary>
        public int Category { get; set; }

        /// <summary>
        /// [User.Trade.Id],[User.Recharge.Id]
        /// </summary>
        public string AssociatedId { get; set; }

        /// <summary>
        /// 交易金额
        /// </summary>
        public decimal Amount { get; set; }

        /// <summary>
        /// 使用余额支付金额
        /// </summary>
        public decimal Balance { get; set; }

        /// <summary>
        /// 是否使用余额支付
        /// </summary>
        public bool UseBalance { get; set; }

        /// <summary>
        /// 支支付方式 0使用余额支付 1使用网银 手机充值卡等
        /// </summary>
        public int PaymentCategory { get; set; }

        /// <summary>
        /// 网关Code
        /// </summary>
        public string Gateway { get; set; }

        /// <summary>
        /// 银行名称
        /// </summary>
        public string BankName { get; set; }

        /// <summary>
        /// 网上银行Id
        /// </summary>
        public int PaymentEBankId { get; set; }

        /// <summary>
        /// 支付平台Id
        /// </summary>
        public int PaymentPlatformId { get; set; }

        /// <summary>
        /// 全国神州行充值卡（卡号17位）、联通一卡充（卡号15位）
        /// </summary>
        public string CardNo { get; set; }

        /// <summary>
        /// 充值卡卡密
        /// </summary>
        public string CardPwd { get; set; }

        /// <summary>
        /// 充值卡面值
        /// </summary>
        public string CardAmount { get; set; }

        /// <summary>
        /// IpAddress
        /// </summary>
        public string IpAddress { get; set; }

        /// <summary>
        /// 第三方编号 支付宝交易号 等
        /// </summary>
        public string ThirdPartyNo { get; set; }

        /// <summary>
        /// 扩展信息
        /// </summary>
        public string Extra { get; set; }

        /// <summary>
        /// 交易状态 0为成功  1为待支付 2为失败
        /// </summary>
        public byte Status { get; set; }
    }
}